package com.lmxdawn.api.dnf.util;

public enum GoldTypeEnum {
    SELF_GOLD( "自营金币", 1),
    PROXY_GOLD( "代理金币", 2),
    SHOP_GOLD( "出售商城金币", 3),
    SHOP_GOLD2( "出售商城金币", 15),
    MD_GOLD( "矛盾", 4),
    JADE_GOLD( "避邪玉", 5),
    S1( "特价商城500-5000", 11),
    S2( "特价商城回收500-5000", 12),
    S3( "特价商城5000+", 13),
    S4( "特价商城回收5000+", 14);


    private Integer type;
    private String label;

    public Integer getType() {
        return type;
    }

    public void setType(Integer type) {
        this.type = type;
    }

    public String getLabel() {
        return label;
    }

    public void setLabel(String label) {
        this.label = label;
    }

    GoldTypeEnum(String label, Integer type) {
        this.label = label;
        this.type = type;
    }

    public static GoldTypeEnum match(Integer type){
        for (GoldTypeEnum anEnum : GoldTypeEnum.values()) {
            if (anEnum.getType().equals(type)) {
                return anEnum;
            }
        }
        return null;
    }
}
